package com.youdoneed.community.shortVideo.dao;

import java.util.List;

import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import com.youdoneed.community.shortVideo.entity.Musiclibrary;
import com.youdoneed.community.shortVideo.vo.RecommendVo;


@Mapper
public interface MusiclibraryMapper {
    int deleteByPrimaryKey(String musicId);

    int insert(Musiclibrary record);

    int insertSelective(Musiclibrary record);

    Musiclibrary selectByPrimaryKey(String musicId);

    int updateByPrimaryKeySelective(Musiclibrary record);

    int updateByPrimaryKey(Musiclibrary record);
    
    List<RecommendVo> findMusicFromLibrary(@Param("typeId")String typeId,@Param("name")String name,
    										@Param("createDateS")String createDateS,@Param("createDateE")String createDateE);
    
    int findMusicFromLibraryForTotal(@Param("typeId")String typeId,@Param("name")String name,
    								 @Param("createDateS")String createDateS,@Param("createDateE")String createDateE);
    
    List<Musiclibrary> findVideoFromMusiclibrary();
    
    List<Musiclibrary> findMusiclibraryByName(String name);
    
    int countMusiclibraryByName(String name);
}

